﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Xml.Linq;

namespace ConsoleApp2
{
    public class Article
    {

        public long Id { get; set; }
        public string Title { get; set; }
        public string Content { get; set; }
        public List<Comment> Comments { get; set; } = new List<Comment>();

        public override string ToString()
        {
            StringBuilder sb = new StringBuilder();
            sb.AppendLine($"{Id}, Title={Title}, Content={Content}");
            foreach(var c in Comments)
            {
                sb.AppendLine("    " + c.ToString());
            }
            return sb.ToString();
        }
    }
}
